package cn.zero.controller;

import cn.zero.domain.MovieTicket;
import cn.zero.result.JSONResult;
import cn.zero.service.MovieService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestControllerAdvice
@RequestMapping("/movie")
public class MovieController {
    @Autowired
    private MovieService movieService;

    @GetMapping("/getMovie/{id}")
    public MovieTicket getMovie(@PathVariable("id") Long id) {
        return movieService.loadById(id);
    }

}
